Remove crashdump.create -- this doesn't make sense.
authorEwan Mellor <ewan@xensource.com>
Thu, 8 Mar 2007 23:16:34 +0000 (23:16 +0000)
committerEwan Mellor <ewan@xensource.com>
Thu, 8 Mar 2007 23:16:34 +0000 (23:16 +0000)
Signed-off-by: Ewan Mellor <ewan@xensource.com>
docs/xen-api/xenapi-datamodel.tex
tools/libxen/include/xen_crashdump.h
tools/libxen/src/xen_crashdump.c

index cce4ae5cc7961b23bc4c121df6e963f8efb45a05..319713e2e2a44c6767b9f90c72b5e000fbee8cec 100644 (file)
@@ -11885,34 +11885,13 @@ $\mathit{RO}_\mathit{ins}$ &  {\tt VDI} & VDI ref & the virtual disk \\
 \hline
 \end{longtable}
 \subsection{Additional RPCs associated with class: crashdump}
-\subsubsection{RPC name:~get\_all}
-
-{\bf Overview:} 
-Return a list of all the crashdumps known to the system.
-
- \noindent {\bf Signature:} 
-\begin{verbatim} ((crashdump ref) Set) get_all (session_id s)\end{verbatim}
-
-
-\vspace{0.3cm}
-
- \noindent {\bf Return Type:} 
-{\tt 
-(crashdump ref) Set
-}
-
-
-references to all objects
-\vspace{0.3cm}
-\vspace{0.3cm}
-\vspace{0.3cm}
-\subsubsection{RPC name:~get\_uuid}
+\subsubsection{RPC name:~destroy}
 
 {\bf Overview:} 
-Get the uuid field of the given crashdump.
+Destroy the specified crashdump.
 
  \noindent {\bf Signature:} 
-\begin{verbatim} string get_uuid (session_id s, crashdump ref self)\end{verbatim}
+\begin{verbatim} void destroy (session_id s, crashdump ref self)\end{verbatim}
 
 
 \noindent{\bf Arguments:}
@@ -11922,7 +11901,7 @@ Get the uuid field of the given crashdump.
 \begin{tabular}{|c|c|p{7cm}|}
  \hline
 {\bf type} & {\bf name} & {\bf description} \\ \hline
-{\tt crashdump ref } & self & reference to the object \\ \hline 
+{\tt crashdump ref } & self & The crashdump to destroy \\ \hline 
 
 \end{tabular}
 
@@ -11930,53 +11909,42 @@ Get the uuid field of the given crashdump.
 
  \noindent {\bf Return Type:} 
 {\tt 
-string
+void
 }
 
 
-value of the field
+
 \vspace{0.3cm}
 \vspace{0.3cm}
 \vspace{0.3cm}
-\subsubsection{RPC name:~get\_VM}
+\subsubsection{RPC name:~get\_all}
 
 {\bf Overview:} 
-Get the VM field of the given crashdump.
+Return a list of all the crashdumps known to the system.
 
  \noindent {\bf Signature:} 
-\begin{verbatim} (VM ref) get_VM (session_id s, crashdump ref self)\end{verbatim}
-
-
-\noindent{\bf Arguments:}
-
-\vspace{0.3cm}
-\begin{tabular}{|c|c|p{7cm}|}
- \hline
-{\bf type} & {\bf name} & {\bf description} \\ \hline
-{\tt crashdump ref } & self & reference to the object \\ \hline 
+\begin{verbatim} ((crashdump ref) Set) get_all (session_id s)\end{verbatim}
 
-\end{tabular}
 
 \vspace{0.3cm}
 
  \noindent {\bf Return Type:} 
 {\tt 
-VM ref
+(crashdump ref) Set
 }
 
 
-value of the field
+references to all objects
 \vspace{0.3cm}
 \vspace{0.3cm}
 \vspace{0.3cm}
-\subsubsection{RPC name:~get\_VDI}
+\subsubsection{RPC name:~get\_uuid}
 
 {\bf Overview:} 
-Get the VDI field of the given crashdump.
+Get the uuid field of the given crashdump.
 
  \noindent {\bf Signature:} 
-\begin{verbatim} (VDI ref) get_VDI (session_id s, crashdump ref self)\end{verbatim}
+\begin{verbatim} string get_uuid (session_id s, crashdump ref self)\end{verbatim}
 
 
 \noindent{\bf Arguments:}
@@ -11994,7 +11962,7 @@ Get the VDI field of the given crashdump.
 
  \noindent {\bf Return Type:} 
 {\tt 
-VDI ref
+string
 }
 
 
@@ -12002,13 +11970,13 @@ value of the field
 \vspace{0.3cm}
 \vspace{0.3cm}
 \vspace{0.3cm}
-\subsubsection{RPC name:~create}
+\subsubsection{RPC name:~get\_VM}
 
 {\bf Overview:} 
-Create a new crashdump instance, and return its handle.
+Get the VM field of the given crashdump.
 
  \noindent {\bf Signature:} 
-\begin{verbatim} (crashdump ref) create (session_id s, crashdump record args)\end{verbatim}
+\begin{verbatim} (VM ref) get_VM (session_id s, crashdump ref self)\end{verbatim}
 
 
 \noindent{\bf Arguments:}
@@ -12018,7 +11986,7 @@ Create a new crashdump instance, and return its handle.
 \begin{tabular}{|c|c|p{7cm}|}
  \hline
 {\bf type} & {\bf name} & {\bf description} \\ \hline
-{\tt crashdump record } & args & All constructor arguments \\ \hline 
+{\tt crashdump ref } & self & reference to the object \\ \hline 
 
 \end{tabular}
 
@@ -12026,21 +11994,21 @@ Create a new crashdump instance, and return its handle.
 
  \noindent {\bf Return Type:} 
 {\tt 
-crashdump ref
+VM ref
 }
 
 
-reference to the newly created object
+value of the field
 \vspace{0.3cm}
 \vspace{0.3cm}
 \vspace{0.3cm}
-\subsubsection{RPC name:~destroy}
+\subsubsection{RPC name:~get\_VDI}
 
 {\bf Overview:} 
-Destroy the specified crashdump instance.
+Get the VDI field of the given crashdump.
 
  \noindent {\bf Signature:} 
-\begin{verbatim} void destroy (session_id s, crashdump ref self)\end{verbatim}
+\begin{verbatim} (VDI ref) get_VDI (session_id s, crashdump ref self)\end{verbatim}
 
 
 \noindent{\bf Arguments:}
@@ -12058,11 +12026,11 @@ Destroy the specified crashdump instance.
 
  \noindent {\bf Return Type:} 
 {\tt 
-void
+VDI ref
 }
 
 
-
+value of the field
 \vspace{0.3cm}
 \vspace{0.3cm}
 \vspace{0.3cm}
index fff0a1a144193911fc1db5c83fd9cca1be3f8bae..00869dbb4cc35331edb8c0ee38a5f53f79feeca6 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2006, XenSource Inc.
+ * Copyright (c) 2006-2007, XenSource Inc.
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
@@ -161,20 +161,6 @@ extern bool
 xen_crashdump_get_by_uuid(xen_session *session, xen_crashdump *result, char *uuid);
 
 
-/**
- * Create a new crashdump instance, and return its handle.
- */
-extern bool
-xen_crashdump_create(xen_session *session, xen_crashdump *result, xen_crashdump_record *record);
-
-
-/**
- * Destroy the specified crashdump instance.
- */
-extern bool
-xen_crashdump_destroy(xen_session *session, xen_crashdump crashdump);
-
-
 /**
  * Get the uuid field of the given crashdump.
  */
@@ -196,6 +182,13 @@ extern bool
 xen_crashdump_get_vdi(xen_session *session, xen_vdi *result, xen_crashdump crashdump);
 
 
+/**
+ * Destroy the specified crashdump
+ */
+extern bool
+xen_crashdump_destroy(xen_session *session, xen_crashdump self);
+
+
 /**
  * Return a list of all the crashdumps known to the system.
  */
index 53504ba249caf4ba5cca7436961e7f6f2105346b..2d3840896e8592f2fc317dd1d7ae56bca860cc32 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2006, XenSource Inc.
+ * Copyright (c) 2006-2007, XenSource Inc.
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
@@ -115,38 +115,24 @@ xen_crashdump_get_by_uuid(xen_session *session, xen_crashdump *result, char *uui
 
 
 bool
-xen_crashdump_create(xen_session *session, xen_crashdump *result, xen_crashdump_record *record)
+xen_crashdump_get_vm(xen_session *session, xen_vm *result, xen_crashdump crashdump)
 {
     abstract_value param_values[] =
         {
-            { .type = &xen_crashdump_record_abstract_type_,
-              .u.struct_val = record }
+            { .type = &abstract_type_string,
+              .u.string_val = crashdump }
         };
 
     abstract_type result_type = abstract_type_string;
 
     *result = NULL;
-    XEN_CALL_("crashdump.create");
-    return session->ok;
-}
-
-
-bool
-xen_crashdump_destroy(xen_session *session, xen_crashdump crashdump)
-{
-    abstract_value param_values[] =
-        {
-            { .type = &abstract_type_string,
-              .u.string_val = crashdump }
-        };
-
-    xen_call_(session, "crashdump.destroy", param_values, 1, NULL, NULL);
+    XEN_CALL_("crashdump.get_VM");
     return session->ok;
 }
 
 
 bool
-xen_crashdump_get_vm(xen_session *session, xen_vm *result, xen_crashdump crashdump)
+xen_crashdump_get_vdi(xen_session *session, xen_vdi *result, xen_crashdump crashdump)
 {
     abstract_value param_values[] =
         {
@@ -157,24 +143,21 @@ xen_crashdump_get_vm(xen_session *session, xen_vm *result, xen_crashdump crashdu
     abstract_type result_type = abstract_type_string;
 
     *result = NULL;
-    XEN_CALL_("crashdump.get_VM");
+    XEN_CALL_("crashdump.get_VDI");
     return session->ok;
 }
 
 
 bool
-xen_crashdump_get_vdi(xen_session *session, xen_vdi *result, xen_crashdump crashdump)
+xen_crashdump_destroy(xen_session *session, xen_crashdump self)
 {
     abstract_value param_values[] =
         {
             { .type = &abstract_type_string,
-              .u.string_val = crashdump }
+              .u.string_val = self }
         };
 
-    abstract_type result_type = abstract_type_string;
-
-    *result = NULL;
-    XEN_CALL_("crashdump.get_VDI");
+    xen_call_(session, "crashdump.destroy", param_values, 1, NULL, NULL);
     return session->ok;
 }